#!/bin/bash -i
# hastily written and copied
# but does the job
# whatever

BOOKMARK_FILE=${HOME}/.local/share/${USER}/.bookmark

append() {
    echo "$*" >> "${BOOKMARK_FILE}"
}

# check existence of todo file, create if not
[ ! -f "${BOOKMARK_FILE}" ] && touch "${BOOKMARK_FILE}"

# for appending lines (removing done via 'done')
[ -n "$*" ] && append "$@" && echo "noted" && exit 0

[ $(($(wc -c < "${BOOKMARK_FILE}"))) -lt 2 ] && echo "nothing to do" && exit 0

cat "${BOOKMARK_FILE}"